package com.qf.util;

import java.util.Base64;

/**
 * @Author AzureSky_X
 * @Date 2020/11/17 17:42
 * @Version 1.0
 */
public class Base64Util {
    //加密
    public static String encode(String str){
        return Base64.getEncoder().encodeToString(str.getBytes());
    }
    //解密
    public static String decode(String str){
        return new String(Base64.getDecoder().decode(str.getBytes()));
    }
}
